package com.taobao.txc.common.c;

import io.netty.buffer.ByteBuf;
import java.io.Serializable;
import java.nio.ByteBuffer;

public class h
  extends F
  implements Serializable
{
  String a;
  long b;
  long c;
  String d;
  String e;
  byte f;
  byte g;
  String h = null;
  public ByteBuffer i = ByteBuffer.allocate(1024);
  
  public String b()
  {
    return this.h;
  }
  
  public void a(String paramString)
  {
    this.h = paramString;
  }
  
  public void b(String paramString)
  {
    this.d = paramString;
  }
  
  public String d()
  {
    return this.e;
  }
  
  public void c(String paramString)
  {
    this.e = paramString;
  }
  
  public long e()
  {
    return this.b;
  }
  
  public byte f()
  {
    return this.f;
  }
  
  public byte g()
  {
    return this.g;
  }
  
  public long h()
  {
    return this.c;
  }
  
  public String i()
  {
    return this.a;
  }
  
  public void d(String paramString)
  {
    this.a = paramString;
  }
  
  public String toString()
  {
    return this.b + ":" + this.c + " BranchRollbackMessage DBname:" + this.e + ",appName:" + this.d + ",commitMode:" + this.f + ",isDelLock:" + this.g + ",udata:" + this.h;
  }
  
  public short b_()
  {
    return 5;
  }
  
  public byte[] c()
  {
    this.i.putLong(this.b);
    this.i.putLong(this.c);
    this.i.put(this.f);
    this.i.put(this.g);
    if (this.a != null)
    {
      arrayOfByte = this.a.getBytes(j);
      this.i.putShort((short)arrayOfByte.length);
      if (arrayOfByte.length > 0) {
        this.i.put(arrayOfByte);
      }
    }
    else
    {
      this.i.putShort((short)0);
    }
    if (this.d != null)
    {
      arrayOfByte = this.d.getBytes(j);
      this.i.putShort((short)arrayOfByte.length);
      if (arrayOfByte.length > 0) {
        this.i.put(arrayOfByte);
      }
    }
    else
    {
      this.i.putShort((short)0);
    }
    if (this.e != null)
    {
      arrayOfByte = this.e.getBytes(j);
      this.i.putShort((short)arrayOfByte.length);
      if (arrayOfByte.length > 0) {
        this.i.put(arrayOfByte);
      }
    }
    else
    {
      this.i.putShort((short)0);
    }
    if (this.h != null)
    {
      arrayOfByte = this.h.getBytes(j);
      this.i.putShort((short)arrayOfByte.length);
      if (arrayOfByte.length > 0) {
        this.i.put(arrayOfByte);
      }
    }
    else
    {
      this.i.putShort((short)0);
    }
    this.i.flip();
    byte[] arrayOfByte = new byte[this.i.limit()];
    this.i.get(arrayOfByte);
    return arrayOfByte;
  }
  
  public boolean a(ByteBuf paramByteBuf)
  {
    int j = paramByteBuf.readableBytes();
    if (j < 26) {
      return false;
    }
    this.b = paramByteBuf.readLong();
    this.c = paramByteBuf.readLong();
    this.f = paramByteBuf.readByte();
    this.g = paramByteBuf.readByte();
    int k = paramByteBuf.readShort();
    j -= 26;
    byte[] arrayOfByte;
    if (k > 0)
    {
      if (j < k) {
        return false;
      }
      j -= k;
      arrayOfByte = new byte[k];
      paramByteBuf.readBytes(arrayOfByte);
      d(new String(arrayOfByte, j));
    }
    k = paramByteBuf.readShort();
    if (k > 0)
    {
      if (j < k) {
        return false;
      }
      j -= k;
      arrayOfByte = new byte[k];
      paramByteBuf.readBytes(arrayOfByte);
      b(new String(arrayOfByte, j));
    }
    k = paramByteBuf.readShort();
    if (k > 0)
    {
      if (j < k) {
        return false;
      }
      j -= k;
      arrayOfByte = new byte[k];
      paramByteBuf.readBytes(arrayOfByte);
      c(new String(arrayOfByte, j));
    }
    k = paramByteBuf.readShort();
    if (k > 0)
    {
      if (j < k) {
        return false;
      }
      arrayOfByte = new byte[k];
      paramByteBuf.readBytes(arrayOfByte);
      a(new String(arrayOfByte, j));
    }
    return true;
  }
}


/* Location:           C:\Users\ibm\Downloads\txc-yun-sample (1)\txc-yun-sample\lib\txc-client-2.0.72.jar
 * Qualified Name:     com.taobao.txc.common.c.h
 * JD-Core Version:    0.7.0.1
 */